<template>
  <div class="my-textarea">
    <el-input
      type="textarea"
      :rows="rows"
      :placeholder="ph"
      v-model="textarea"
      :style="'width:' + width + 'px;'"
    >
    </el-input>
  </div>
</template>

<script>
export default {
  props: ["ph", "rows", "width"],
  data() {
    return {
      textarea: "",
    };
  },
  watch: {
    textarea() {
      this.$emit("value", this.textarea);
    },
  },
};
</script>

<style>
.my-textarea .el-textarea__inner {
  background-color: #f2f2f2;
  border: none;
  resize: none;
}
</style>